{% extends '../../../layouts/skins/v2/layout.volt' %}
{% block content %}
    <div ng-controller="movieController">
        <div>
            <div>
                <div class="page-header">
                    <h3>
                        <a href="">
                            Phim đang chiếu
                        </a>
                    </h3>
                </div>
                <div class="row">
                    <div class="subtray">
                        {% for new in news %}
                            <div class="item col-sm-6 col-md-3">
                                <div class="thumbnail">
                                    <a href="{{url('video/detail/'~new.getId())}}" title="{{new.videoDescription.getName()}}">
                                        {% if(new.imageLink.getFirst()) %}
                                            {{ image('/public/files/' ~ new.imageLink.getFirst().images.getImagePath() , 'width' : '250','height':'250') }}
                                        {% else %}
                                            {{ image('/public/files/default.jpg'  , 'width' : '250','height':'250') }}
                                        {% endif %}
                                    </a>
                                    <div class="caption">
                                        <h4 class="title">
                                            <a href="#" data-title="{{new.videoDescription.getName()}}" class="litebox icon play-trailer">
                                                {{new.videoDescription.getName()}}
                                            </a>
                                        </h4>
                                    </div>
                                </div>
                            </div>
                        {% endfor %}
                    </div>

                </div>
            </div>

            <div>
                <div class="page-header">
                    <h3>
                        <a href="">
                            Phim xem nhiều
                        </a>
                    </h3>
                </div>
                <div class="row">
                    <div class="subtray">
                        {% for new in news %}
                            <div class="item col-sm-6 col-md-3">
                                <div class="thumbnail">
                                    <a href="{{url('video/detail/'~new.getId())}}" title="{{new.videoDescription.getName()}}">
                                        {% if(new.imageLink.getFirst()) %}
                                            {{ image('/public/files/' ~ new.imageLink.getFirst().images.getImagePath() , 'width' : '250','height':'250') }}
                                        {% else %}
                                            {{ image('/public/files/default.jpg'  , 'width' : '250','height':'250') }}
                                        {% endif %}
                                    </a>
                                    <div class="caption">
                                        <h4 class="title">
                                            <a href="#" data-title="{{new.videoDescription.getName()}}" class="litebox icon play-trailer">
                                                {{new.videoDescription.getName()}}
                                            </a>
                                        </h4>
                                    </div>
                                </div>
                            </div>
                        {% endfor %}
                    </div>

                </div>
            </div>

        </div>
    </div>
{% endblock %}